<div class="col-sm-12 mt20" style="margin-bottom: 200px;">
    <!-- 搜索栏 -->
    <div class="panel panel-default">
        <div class="panel-body" ng-keyup="myKeyup($event)">
            <div class="col-sm-12">
                <div class="row">
                    <div class="col-lg-2">
                        <input type="text" class="form-control" placeholder="产品名称" ng-model="searchform.name">
                    </div>
                    <div class="col-lg-2">
                        <input type="text" class="form-control" placeholder="产品编号" ng-model="searchform.code">
                    </div>
                    <div class="col-lg-2">
                        <ui-select ng-model="searchform.sale_category" theme="bootstrap">
                            <ui-select-match placeholder="产品类型">{{$select.selected.name}}</ui-select-match>
                            <ui-select-choices repeat="item.code as item in goodslCategoryist | filter: $select.search">
                                <span ng-bind-html="item.name | highlight: $select.search"></span>
                            </ui-select-choices>
                        </ui-select>
                    </div>
                    <div class="col-lg-2">
                        <!-- <select type="text" class="form-control" placeholder="产品分类" ng-model="searchform.type">
                            <option value="">全部</option>
                            <option value="1">消费</option>
                            <option value="2">储值</option>
                        </select> -->
                    </div>
                    <div class="col-lg-2">
                    </div>
                    <div class="col-lg-2">
                        <button class="btn btn-info search btn-block" ng-click="loadlist(1)">立即搜索</button>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <!-- 景区产品列表 -->
    <div class="panel panel-default">
        <div class="panel-body">
            <table class="table table-condensed table-hover table-bordered">
                <thead>
                    <tr>
                        <!-- <th>
                            <input type="checkbox" class="form-control" ng-model="isAllSelected">
                        </th> -->
                        <!-- <th style="width: 2%;text-align:center;">
                            <label class="i-checks m-b-none">
                                <input type="checkbox" class="form-control" ng-model="isAllSelected">
                                <i></i>
                            </label>
                        </th> -->
                        <th class="text-center col-xs-2">示例图片</th>
                        <th class="text-center">产品信息</th>
                        <th class="text-center">库存信息</th>
                        <!-- <th class="text-center">产品状态</th> -->
                        <th class="text-center col-xs-3">选择</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="info in goodslist">
                        <!-- <td style="width: 2%;text-align:center;">
                            <label class="i-checks m-b-none">
                                <input type="checkbox" ng-model="info.isSelected">
                                <i></i>
                            </label>
                        </td> -->
                        <td>
                            <img src="{{info.img}}" alt="示例图片" width="260px" height="120px" />
                        </td>
                        <td>
                            名称：{{info.name}}
                            <!-- <span class="label bg-info pull-right m-t-xs">{{info.sale_category==1?'雪具':'零食'}}</span><br/> -->
                            <br/> 编号：{{info.code}}
                            <br/>
                            <span ng-if="info.is_define_price == '0'">价格：{{info.price}} 元</span>
                            <!-- <div class="input-group col-xs-8" ng-if="info.is_define_price == '1'">
                                <span class="input-group-addon">价格</span>
                                <input type="number" class="form-control" ng-model="info.cus_price">
                                <span class="input-group-addon">元</span>
                            </div> -->
                        </td>
                        <td>
                            <div style="margin-left: 27%">
                                总库存：{{info.stock == -1 ? '无限' : info.stock}}
                                <br/> 已出售：{{info.sell_num}}
                                <br/> 剩余库存：{{info.remaining_stock == -1 ? '无限' : info.remaining_stock}}
                            </div>
                        </td>
                        <!-- <td class="text-center">
                            <br/>{{info.state==1?'已上架':info.state==2?'下架':'未上架'}}
                        </td> -->
                        <td class="text-center">
                            <br/>
                            <div class="input-group" ng-if="info.is_define_price !== '1'">
                                <span class="input-group-addon">数量</span>
                                <!-- <span class="input-group-addon">-</span> -->
                                <input type="number" class="form-control" min="0" ng-model="info.number">
                                <!-- <span class="input-group-addon">+</span> -->
                                <span class="input-group-addon">个</span>
                            </div>
                            <div class="input-group" ng-if="info.is_define_price == '1'">
                                <span class="input-group-addon">价格</span>
                                <input type="number" class="form-control" ng-model="info.cus_price">
                                <span class="input-group-addon">元</span>
                            </div>
                            <!-- <button type="button" class="btn btn-info btn-md" ng-click="updateGoods(info)">购买</button> -->
                        </td>
                    </tr>
                </tbody>
            </table>

            <div class="text-right">
                <nav class="navbar navbar-default navbar-fixed-bottom" style="height: auto;">
                    <div class="container">
                        <div class="col-xs-12 row">
                            <div class="col-xs-9 row">
                                <div class="col-xs-12 row" ng-repeat="info in goodslist" ng-show="(info.is_define_price != '1' && info.number > 0) || (info.is_define_price == '1' && info.cus_price > 0)">
                                    <div class="col-xs-6 row text-left">
                                        <h2 class="text-primary">{{info.name}}</h2>
                                    </div>
                                    <div class="col-xs-6 row text-center">
                                        <h2 class="text-primary">{{info.number}}</h2>
                                    </div>
                                </div>
                            </div>
                            <div class="col-xs-3 row" style="bottom: 5px;">
                                <div class="row col-xs-12 text-right">
                                    <h2 class="pull-right">
                                        <span class="text-muteds">总价：</span>
                                        <span class="text-danger">{{order.total_price}}</span>
                                    </h2>
                                </div>
                                <div class="row col-xs-12 text-right">
                                    <a type="button" class="btn btn-lg btn-block btn-danger pull-right" style="margin-top: 5%; margin-left: 50%;" ng-click="createOrder()">购 买</a>
                                </div>
                            </div>
                        </div>
                    </div>
                </nav>
            </div>

            <div class="text-right" ng-show="false">
                <pagination total-items="totalItems" ng-model="currentPage" ng-change="loadlist()" previous-text="上一页" next-text="下一页" first-text="首页"
                    last-text="尾页" max-size="maxSize" boundary-links="true" rotate="false" items-per-page="itemsPerPage" class="m-t-none m-b">
                </pagination>
            </div>
        </div>
    </div>
</div>